#include "Thread.hpp"
#include <unistd.h>
#include <vector>

using namespace ThreadModlue;

//可以传递对象
class ThreadData
{
public:
    pthread_t tid;
    string name;
};

void Count(ThreadData td)
{
    while(true)
    {
        cout << "我是一个新线程" << endl;
        sleep(1);
    }
}

int main()
{
    ThreadData td;
    Thread<ThreadData> t(Count, td);

    t.Start();
    t.Join();
    return 0;
}